package org.xin.framework.service;


import org.xin.framework.base.service.IBaseService;
import org.xin.framework.pojo.entity.SysDictionary;
import org.xin.framework.pojo.entity.SysDictionaryItem;

import javax.validation.constraints.NotBlank;
import java.util.List;

/**
 * <p>
 * 系统模块-字典表 服务接口
 * </p>
 *
 * @author: xin
 * @date: Create in 2021-09-29
 */

public interface ISysDictionaryService extends IBaseService<SysDictionary> {
    /**
     * 根据code获取字典条目值
     * @param code
     * @return
     */
    List<SysDictionaryItem> selectNamesByCode(@NotBlank String code);

    /**
     * 根据code获取字典条目值
     * @param code
     * @return
     */
    String selectItemNameByCode(@NotBlank String code);

    /**
     * @desc <p> 根据code获取字典 </p>
     * @author xin
     * @date 2021/10/9
     */
    SysDictionary selectByCode(@NotBlank String code);
}

